package com.hyhigh.controller;

import com.hyhigh.pojo.Employee;
import com.hyhigh.service.EmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;

@Controller
public class EmployeeController {

    @Autowired
    private EmployeeService employeeService;

    @RequestMapping("employee")
    public String employeeAll(Model model) {
        List<Employee> list = employeeService.employeeAll();
        System.err.println("执行员工管理数据");
        model.addAttribute("employeeAll", list);
        return "employee";
    }



}
